/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package za.ac.cput.assignment2.ocpcorrect.ocpimpl;

import za.ac.cput.assignment2.ocpcorrect.LoanRequestValid;
import za.ac.cput.assignment2.ocpcorrect.Validate;

/**
 *
 * @author yandiswa
 */
public class LoanRequestImpl implements LoanRequestValid {
    double accBalance;
    int tPeriod;
    public void SetBalance(double balance)
    {
        accBalance = balance;
    }

    public void SetPeriod(int period)
    {
        tPeriod = period;
    }
     public String GetApproval(Validate val)
    {
        if(val.IsValid(accBalance))
            return "Loan Approved";
        else
            return "Insufficient Balance";
    }

    
}
